//字段类型
export enum FIELD_TYPES {
  text = 'text',
  number = 'number',
  select = 'select',
  datetime = 'datetime',
  switch = 'switch'
}

//按钮操作类型
export enum BUTTON_ACTION_TYPES {
  add = 'add',
  update = 'update',
  delete = 'delete',
  refresh = 'refresh'
}

//按钮类型
export enum BUTTON_TYPES {
  default = 'default',
  primary = 'primary',
}

//方法类型
export enum METHOD_TYPES {
  DELETE = 'DELETE',
  POST = 'POST',
  PUT = 'PUT',
  GET = 'GET'
}

export const FIELD = [
  { label: '文本', value: FIELD_TYPES.text },
  { label: '数字', value: FIELD_TYPES.number },
  { label: '下拉框', value: FIELD_TYPES.select },
  { label: '日期时间', value: FIELD_TYPES.datetime },
  { label: '开关', value: FIELD_TYPES.switch }
]

export const BUTTON = [
  { label: '默认', value: BUTTON_TYPES.default },
  { label: '主要', value: BUTTON_TYPES.primary }
]

export const BUTTON_ACTION = [
  { label: '添加', value: BUTTON_ACTION_TYPES.add },
  { label: '更新', value: BUTTON_ACTION_TYPES.update },
  { label: '删除', value: BUTTON_ACTION_TYPES.delete },
  { label: '刷新', value: BUTTON_ACTION_TYPES.refresh }
]

export const METHOD = [
  { label: 'DELETE', value: METHOD_TYPES.DELETE },
  { label: 'POST', value: METHOD_TYPES.POST },
  { label: 'PUT', value: METHOD_TYPES.PUT },
  { label: 'GET', value: METHOD_TYPES.GET }
]

export const BOOLEAN = [
  { label: '是', value: 1 },
  { label: '否', value: 0 }
]